package cn.work.service;

import cn.work.bean.userbean;
import cn.work.dao.userDao;

import java.sql.SQLException;

public class userService {
    userbean userservice = null;
    userDao userdao = new userDao();
    public userbean login(userbean user) {
        System.out.printf("service层账号为：%s，密码为%s\n",user.getUsername(),user.getPassword());//测试信息
        userservice = userDao.selectlogin(user);
        if(userservice!=null){
            return userservice;
        }
        return null;
    }
}
